package com.pwc.conversionTool.entity;

import java.io.Serializable;

import javax.persistence.Transient;

import org.codehaus.jackson.annotate.JsonIgnore;

import com.googlecode.objectify.Key;
import com.googlecode.objectify.annotation.Entity;
import com.googlecode.objectify.annotation.Id;
import com.googlecode.objectify.annotation.Index;


@Entity
public class Project implements Serializable{


	/**
	 * 
	 */
	private static long serialVersionUID = -5040347982953529007L;	
	
	
	@Id private Long id;
	
	@Index private String projectName;
	
	private String description;	
	
	@Index Key<Account> account;
	


	public Project() {
		super();
	}


	public Project(Long id, String projectName, String description, Key<com.pwc.conversionTool.entity.Account> account) {
		super();
		this.id = id;
		this.projectName = projectName;
		this.description = description;
		this.account = account;
	}


	public Long getId() {
		return id;
	}

	public void setId(Long id) {
		this.id = id;
	}



	public String getProjectName() {
		return projectName;
	}

	public void setProjectName(String projectName) {
		this.projectName = projectName;
	}

	public String getDescription() {
		return description;
	}

	public void setDescription(String description) {
		this.description = description;
	}

	@JsonIgnore
	public Key<Account> getAccount() {
		return account;
	}


	public void setAccount(Key<Account> account) {
		this.account = account;
	}
	
	
	
	
	@JsonIgnore
	@Transient
	public Key<Project> getKey() {
	   return Key.create(Project.class, id);
	}
	
	
	
	
}
